package com.itheima.thread.Demo5;

public class Test {
    public static void main(String[] args) throws InterruptedException {

        new Thread(()->{
            for (int i = 0; i < 10; i++) {
                System.out.println("普通线程第"+i+"次执行");
            }
        }).start();

        Thread t = new Thread(()->{
            for (int i = 0; i < 100; i++) {
                System.out.println("守护线程第"+i+"次执行");
            }
        });
        t.setDaemon(true);
        t.start();

        Thread.sleep(100);
        new Thread(() -> System.out.println("线程1")).start();
    }
}
